import request from '@/utils/request'
// 获取权限列表
export const getPermissions = (_limit, _start) => request({
  url: '/permissions',
  params: {
    _limit,
    _start
  }
})
// 获取权限总数
export const getPermissionsCount = () => request({
  url: '/permissions/count'
})
// 根据id获取权限列表
export const getPermissionsId = (id) => request({
  url: '/permissions/' + id
})
// 新建权限
export const postPermissions = data => request({
  url: '/permissions',
  method: 'post',
  data
})
// 编辑权限
export const putProperties = data => request({
  url: '/permissions/' + data.id,
  method: 'put',
  data
})
// 删除权限
export const delPermissions = id => request({
  url: '/permissions/' + id,
  method: 'DELETE'
})
